import request from '@/utils/request'

export function menuTreeTable(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/menu/treeTable`,
    method: 'post',
    data: query
  })
}

export function menuTreeData(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/menu/treeData`,
    method: 'post',
    data: query
  })
}

export function menuLoad(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/menu/load`,
    method: 'get',
    params: query
  })
}

export function menuSave(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/menu/save`,
    method: 'post',
    data: query
  })
}

export function menuDelete(query) {
  return request({
    url: `${process.env.VUE_APP_MODULE_ADMIN_API}/api/system/menu/delete`,
    method: 'post',
    data: query
  })
}
